
<%@ page import="com.walkingfiles.registry.Transfer" %>
<!doctype html>
<html>
	<head>
		<meta name="layout" content="main">
		<g:set var="entityName" value="${message(code: 'transfer.label', default: 'Transfer')}" />
		<title><g:message code="default.list.label" args="[entityName]" /></title>
	</head>
	<body>
	<div id="outer">
		<a href="#list-transfer" class="skip" tabindex="-1"><g:message code="default.link.skip.label" default="Skip to content&hellip;"/></a>
		<g:render template="/layouts/menu"/>
		<div id="list-transfer" class="content scaffold-list" role="main">
			<h1><g:message code="default.list.label" args="[entityName]" /></h1>
			<g:if test="${flash.message}">
			<div class="message" role="status">${flash.message}</div>
			</g:if>
			<g:if test="${!transferInstanceList}">
			<p><g:message code="transfer.list.no.transfers" default="No transfers found"/></p>
			</g:if>
			<g:else>
			<table>
				<thead>
					<tr>

						<g:sortableColumn property="number" title="${message(code: 'transfer.number.label', default: 'Number')}" />					
						<th><g:message code="transfer.sourceArea.label" default="Source Area" /></th>

						<g:sortableColumn property="sendDate" title="${message(code: 'transfer.sendDate.label', default: 'Send Date')}" />

						<th><g:message code="transfer.destinationArea.label" default="Destination Area" /></th>

						<g:sortableColumn property="receptionDate" title="${message(code: 'transfer.receptionDate.label', default: 'Reception Date')}" />
						<g:sortableColumn property="modifiedDate" title="${message(code: 'transfer.modifiedDate.label', default: 'Modified Date')}" />
					
					
					</tr>
				</thead>
				<tbody>
				<g:each in="${transferInstanceList}" status="i" var="transferInstance">
					<tr class="${(i % 2) == 0 ? 'even' : 'odd'}">

						<td><g:link action="show" id="${transferInstance.id}">${fieldValue(bean: transferInstance, field: "id")}</g:link></td>

						<td>${fieldValue(bean: transferInstance, field: "sourceArea.name")}</td>

						<td><g:formatDate date="${transferInstance.sendDate}" /></td>

						<td>${fieldValue(bean: transferInstance, field: "destinationArea.name")}</td>

						<td><g:formatDate date="${transferInstance.receptionDate}" /></td>

						<td><g:formatDate date="${transferInstance.modifiedDate}" /></td>
					
					</tr>
				</g:each>
				</tbody>
			</table>
			<div class="pagination">
				<g:paginate total="${transferInstanceTotal}" />
			</div>
			</g:else>
		</div>
	</div>
	</body>
</html>
